package com.example.aicooking.service.imp;

import com.example.aicooking.entity.dto.IngredientDTO;
import com.example.aicooking.mapper.IngredientMapper;
import com.example.aicooking.service.IngredientService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class IngredientServiceImpl implements IngredientService {
    @Autowired
    private IngredientMapper ingredientMapper;

    @Override
    public List<IngredientDTO> getIngredientsByWorkId(Integer workId) {
        return ingredientMapper.findIngredientsByWorkId(workId);
    }
}
